# 作者：宋安康
# 开发时间：2023/5/21 16:08
list1 = [10, 20, 30, 40, 50, 60, 70, 80]
# start=1,stop=6,step=1
# print(list1[1:6:1])
list2 = list1[1:6:1]
print("list2", id(list2))
print(list1[1:6])   # default step = 1
print(list1[1:6:])  # default step = 1
print(list1[1:6:2])   # default step = 2
print(list1[:6:2])    # default start
print(list1[1:6:])    # stop start

print("--------------------------")
print("initial list", list1)
print(list1[::-1])    # stop start
print(list1[7::-1])
print(list1[6::-2])
